package object05;

public class Demo {
    public static void main(String[] args) {
        Person p1 = new Person("三丰", 40);
        Animal animal = new Animal();
        boolean b1 = p1.equals(animal);//Animal cannot be cast to class object05.Person
                                        //Animal 不能被强制转化为 Person
        Person p2 = new Person("四风", 30);
        Person p3 = new Person("三丰", 40);
        boolean b2 = p1.equals(p2);
        boolean b3 = p1.equals(p3);
        System.out.println(b1 + "  " + b2 + "  " + b3);
    }

}
